﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace BL
{
    //class Article
    //{
    //    private int stockId;
    //    int attribute;

    //    public Article(int articleNumber, int attribute)
    //    {
    //        this.articleNumber = articleNumber;
    //        this.attribute = attribute;
    //    }

    //    internal static List<Article> getAllArticleUpdates(int userId)
    //    {
    //        dbDataContext db = new dbDataContext();

    //        List<Article> updatedArticles = new List<Article>();

    //        var query =
    //            from a in db.tArticles
    //            where a.timeUpdated > (from u in db.tUsers
    //                                   where u.id == userId
    //                                   select u).FirstOrDefault().lastSeen
    //            orderby a.timeUpdated ascending
    //            select a;


    //        foreach (var item in query)
    //        {
    //            Article article = new Article(item.articleNumber, item.attribute);
    //            updatedArticles.Add(article);
    //        }

    //        return updatedArticles;

    //    }

    //}
}
